﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using TaskToLineUp;
using EtlComm;
using ETLDispatcher;
using System.Threading;
using System.Windows.Forms;
using StructureMap;
using System.Data.OleDb;
using ETLHandler;

namespace ChinaPetroETL
{
    //class Program
    //{
    //    static void Main(string[] args)
    //    {
    //        ObjectFactory.Initialize(x =>
    //        {
    //            x.UseDefaultStructureMapConfigFile = true;
    //        });
            
    //        ManualResetEvent mre = new ManualResetEvent(false);
    //        try
    //        {
    //            //获取任务列表
    //            IList<StationObject> lstSO = TaskQueuer.StationObjectList;
    //            IEDTDispatcher disp = new EtlDispatcher();
    //            disp.log = LogFactory.CreateLog<ClientBaseLog>();
    //            disp.Active = true;
    //            //调度任务
    //            disp.Dispatch(lstSO);
    //        }
    //        catch (System.Exception ex)
    //        {
    //            Console.WriteLine(ex.Message);
    //        }
    //        mre.WaitOne();
    //    }
    //} 

    class Prorgam2
    {
         
        static void Main(string[] args)
        {
            ObjectFactory.Initialize(x =>
            {
                x.UseDefaultStructureMapConfigFile = true;
            });
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            Application.Run(new frmMonitor());
           
        }
    }
}
